import {DataView} from './DataView';

class JSONDataView extends DataView{
  constructor(){
    super();
    console.log(`创建JSON格式数据`);
    this.data = JSON.stringify({foo:'foo', bar:'bar'});
  }
  convertData():void{
    this.data = '<root><foo></foo><bar></bar></root>';
  }
  isNeedConvert():boolean{
    return true;
  }
}

export {JSONDataView}